package com.kfm.pm;

import java.util.Objects;

public class TVPlay {

    private String name;
    private int series;
    public TVPlay () {}

    public TVPlay(String name, int series) {
        this.name = name;
        this.series = series;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getSeries() {
        return series;
    }

    public void setSeries(int series) {
        this.series = series;
    }

    @Override
    public String toString() {
        return "TVPlay{" +
                "name='" + name + '\'' +
                ", series=" + series +
                '}';
    }

    @Override
    public boolean equals(Object object) {
        if (this == object) return true;
        if (object == null || getClass() != object.getClass()) return false;
        TVPlay tvPlay = (TVPlay) object;
        return series == tvPlay.series && Objects.equals(name, tvPlay.name);
    }

    @Override
    public int hashCode() {
        return Objects.hash(name, series);
    }
}
